package com.jieshuibao.model.db;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

public class RedEnvelopesExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    private int pageIndex;

    private int pageSize;

    public RedEnvelopesExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    public void setPageIndex(int pageIndex) {
        this.pageIndex=pageIndex;
    }

    public int getPageIndex() {
        return this.pageIndex;
    }

    public void setPageSize(int pageSize) {
        this.pageSize=pageSize;
    }

    public int getPageSize() {
        return this.pageSize;
    }

    public RedEnvelopesExample(int pageIndex, int pageSize) {
        this();
        this.pageIndex=pageIndex;
        this.pageSize=pageSize;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andUuidIsNull() {
            addCriterion("uuid is null");
            return (Criteria) this;
        }

        public Criteria andUuidIsNotNull() {
            addCriterion("uuid is not null");
            return (Criteria) this;
        }

        public Criteria andUuidEqualTo(String value) {
            addCriterion("uuid =", value, "uuid");
            return (Criteria) this;
        }

        public Criteria andUuidNotEqualTo(String value) {
            addCriterion("uuid <>", value, "uuid");
            return (Criteria) this;
        }

        public Criteria andUuidGreaterThan(String value) {
            addCriterion("uuid >", value, "uuid");
            return (Criteria) this;
        }

        public Criteria andUuidGreaterThanOrEqualTo(String value) {
            addCriterion("uuid >=", value, "uuid");
            return (Criteria) this;
        }

        public Criteria andUuidLessThan(String value) {
            addCriterion("uuid <", value, "uuid");
            return (Criteria) this;
        }

        public Criteria andUuidLessThanOrEqualTo(String value) {
            addCriterion("uuid <=", value, "uuid");
            return (Criteria) this;
        }

        public Criteria andUuidLike(String value) {
            addCriterion("uuid like", value, "uuid");
            return (Criteria) this;
        }

        public Criteria andUuidNotLike(String value) {
            addCriterion("uuid not like", value, "uuid");
            return (Criteria) this;
        }

        public Criteria andUuidIn(List<String> values) {
            addCriterion("uuid in", values, "uuid");
            return (Criteria) this;
        }

        public Criteria andUuidNotIn(List<String> values) {
            addCriterion("uuid not in", values, "uuid");
            return (Criteria) this;
        }

        public Criteria andUuidBetween(String value1, String value2) {
            addCriterion("uuid between", value1, value2, "uuid");
            return (Criteria) this;
        }

        public Criteria andUuidNotBetween(String value1, String value2) {
            addCriterion("uuid not between", value1, value2, "uuid");
            return (Criteria) this;
        }

        public Criteria andMoneyIsNull() {
            addCriterion("money is null");
            return (Criteria) this;
        }

        public Criteria andMoneyIsNotNull() {
            addCriterion("money is not null");
            return (Criteria) this;
        }

        public Criteria andMoneyEqualTo(Double value) {
            addCriterion("money =", value, "money");
            return (Criteria) this;
        }

        public Criteria andMoneyNotEqualTo(Double value) {
            addCriterion("money <>", value, "money");
            return (Criteria) this;
        }

        public Criteria andMoneyGreaterThan(Double value) {
            addCriterion("money >", value, "money");
            return (Criteria) this;
        }

        public Criteria andMoneyGreaterThanOrEqualTo(Double value) {
            addCriterion("money >=", value, "money");
            return (Criteria) this;
        }

        public Criteria andMoneyLessThan(Double value) {
            addCriterion("money <", value, "money");
            return (Criteria) this;
        }

        public Criteria andMoneyLessThanOrEqualTo(Double value) {
            addCriterion("money <=", value, "money");
            return (Criteria) this;
        }

        public Criteria andMoneyIn(List<Double> values) {
            addCriterion("money in", values, "money");
            return (Criteria) this;
        }

        public Criteria andMoneyNotIn(List<Double> values) {
            addCriterion("money not in", values, "money");
            return (Criteria) this;
        }

        public Criteria andMoneyBetween(Double value1, Double value2) {
            addCriterion("money between", value1, value2, "money");
            return (Criteria) this;
        }

        public Criteria andMoneyNotBetween(Double value1, Double value2) {
            addCriterion("money not between", value1, value2, "money");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumIsNull() {
            addCriterion("sendPhoneNum is null");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumIsNotNull() {
            addCriterion("sendPhoneNum is not null");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumEqualTo(String value) {
            addCriterion("sendPhoneNum =", value, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumNotEqualTo(String value) {
            addCriterion("sendPhoneNum <>", value, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumGreaterThan(String value) {
            addCriterion("sendPhoneNum >", value, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumGreaterThanOrEqualTo(String value) {
            addCriterion("sendPhoneNum >=", value, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumLessThan(String value) {
            addCriterion("sendPhoneNum <", value, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumLessThanOrEqualTo(String value) {
            addCriterion("sendPhoneNum <=", value, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumLike(String value) {
            addCriterion("sendPhoneNum like", value, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumNotLike(String value) {
            addCriterion("sendPhoneNum not like", value, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumIn(List<String> values) {
            addCriterion("sendPhoneNum in", values, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumNotIn(List<String> values) {
            addCriterion("sendPhoneNum not in", values, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumBetween(String value1, String value2) {
            addCriterion("sendPhoneNum between", value1, value2, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendPhoneNumNotBetween(String value1, String value2) {
            addCriterion("sendPhoneNum not between", value1, value2, "sendPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumIsNull() {
            addCriterion("userPhoneNum is null");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumIsNotNull() {
            addCriterion("userPhoneNum is not null");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumEqualTo(String value) {
            addCriterion("userPhoneNum =", value, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumNotEqualTo(String value) {
            addCriterion("userPhoneNum <>", value, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumGreaterThan(String value) {
            addCriterion("userPhoneNum >", value, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumGreaterThanOrEqualTo(String value) {
            addCriterion("userPhoneNum >=", value, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumLessThan(String value) {
            addCriterion("userPhoneNum <", value, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumLessThanOrEqualTo(String value) {
            addCriterion("userPhoneNum <=", value, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumLike(String value) {
            addCriterion("userPhoneNum like", value, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumNotLike(String value) {
            addCriterion("userPhoneNum not like", value, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumIn(List<String> values) {
            addCriterion("userPhoneNum in", values, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumNotIn(List<String> values) {
            addCriterion("userPhoneNum not in", values, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumBetween(String value1, String value2) {
            addCriterion("userPhoneNum between", value1, value2, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andUserPhoneNumNotBetween(String value1, String value2) {
            addCriterion("userPhoneNum not between", value1, value2, "userPhoneNum");
            return (Criteria) this;
        }

        public Criteria andSendDateIsNull() {
            addCriterion("sendDate is null");
            return (Criteria) this;
        }

        public Criteria andSendDateIsNotNull() {
            addCriterion("sendDate is not null");
            return (Criteria) this;
        }

        public Criteria andSendDateEqualTo(Date value) {
            addCriterion("sendDate =", value, "sendDate");
            return (Criteria) this;
        }

        public Criteria andSendDateNotEqualTo(Date value) {
            addCriterion("sendDate <>", value, "sendDate");
            return (Criteria) this;
        }

        public Criteria andSendDateGreaterThan(Date value) {
            addCriterion("sendDate >", value, "sendDate");
            return (Criteria) this;
        }

        public Criteria andSendDateGreaterThanOrEqualTo(Date value) {
            addCriterion("sendDate >=", value, "sendDate");
            return (Criteria) this;
        }

        public Criteria andSendDateLessThan(Date value) {
            addCriterion("sendDate <", value, "sendDate");
            return (Criteria) this;
        }

        public Criteria andSendDateLessThanOrEqualTo(Date value) {
            addCriterion("sendDate <=", value, "sendDate");
            return (Criteria) this;
        }

        public Criteria andSendDateIn(List<Date> values) {
            addCriterion("sendDate in", values, "sendDate");
            return (Criteria) this;
        }

        public Criteria andSendDateNotIn(List<Date> values) {
            addCriterion("sendDate not in", values, "sendDate");
            return (Criteria) this;
        }

        public Criteria andSendDateBetween(Date value1, Date value2) {
            addCriterion("sendDate between", value1, value2, "sendDate");
            return (Criteria) this;
        }

        public Criteria andSendDateNotBetween(Date value1, Date value2) {
            addCriterion("sendDate not between", value1, value2, "sendDate");
            return (Criteria) this;
        }

        public Criteria andReceiveDateIsNull() {
            addCriterion("receiveDate is null");
            return (Criteria) this;
        }

        public Criteria andReceiveDateIsNotNull() {
            addCriterion("receiveDate is not null");
            return (Criteria) this;
        }

        public Criteria andReceiveDateEqualTo(Date value) {
            addCriterion("receiveDate =", value, "receiveDate");
            return (Criteria) this;
        }

        public Criteria andReceiveDateNotEqualTo(Date value) {
            addCriterion("receiveDate <>", value, "receiveDate");
            return (Criteria) this;
        }

        public Criteria andReceiveDateGreaterThan(Date value) {
            addCriterion("receiveDate >", value, "receiveDate");
            return (Criteria) this;
        }

        public Criteria andReceiveDateGreaterThanOrEqualTo(Date value) {
            addCriterion("receiveDate >=", value, "receiveDate");
            return (Criteria) this;
        }

        public Criteria andReceiveDateLessThan(Date value) {
            addCriterion("receiveDate <", value, "receiveDate");
            return (Criteria) this;
        }

        public Criteria andReceiveDateLessThanOrEqualTo(Date value) {
            addCriterion("receiveDate <=", value, "receiveDate");
            return (Criteria) this;
        }

        public Criteria andReceiveDateIn(List<Date> values) {
            addCriterion("receiveDate in", values, "receiveDate");
            return (Criteria) this;
        }

        public Criteria andReceiveDateNotIn(List<Date> values) {
            addCriterion("receiveDate not in", values, "receiveDate");
            return (Criteria) this;
        }

        public Criteria andReceiveDateBetween(Date value1, Date value2) {
            addCriterion("receiveDate between", value1, value2, "receiveDate");
            return (Criteria) this;
        }

        public Criteria andReceiveDateNotBetween(Date value1, Date value2) {
            addCriterion("receiveDate not between", value1, value2, "receiveDate");
            return (Criteria) this;
        }

        public Criteria andRedTypeIsNull() {
            addCriterion("redType is null");
            return (Criteria) this;
        }

        public Criteria andRedTypeIsNotNull() {
            addCriterion("redType is not null");
            return (Criteria) this;
        }

        public Criteria andRedTypeEqualTo(String value) {
            addCriterion("redType =", value, "redType");
            return (Criteria) this;
        }

        public Criteria andRedTypeNotEqualTo(String value) {
            addCriterion("redType <>", value, "redType");
            return (Criteria) this;
        }

        public Criteria andRedTypeGreaterThan(String value) {
            addCriterion("redType >", value, "redType");
            return (Criteria) this;
        }

        public Criteria andRedTypeGreaterThanOrEqualTo(String value) {
            addCriterion("redType >=", value, "redType");
            return (Criteria) this;
        }

        public Criteria andRedTypeLessThan(String value) {
            addCriterion("redType <", value, "redType");
            return (Criteria) this;
        }

        public Criteria andRedTypeLessThanOrEqualTo(String value) {
            addCriterion("redType <=", value, "redType");
            return (Criteria) this;
        }

        public Criteria andRedTypeLike(String value) {
            addCriterion("redType like", value, "redType");
            return (Criteria) this;
        }

        public Criteria andRedTypeNotLike(String value) {
            addCriterion("redType not like", value, "redType");
            return (Criteria) this;
        }

        public Criteria andRedTypeIn(List<String> values) {
            addCriterion("redType in", values, "redType");
            return (Criteria) this;
        }

        public Criteria andRedTypeNotIn(List<String> values) {
            addCriterion("redType not in", values, "redType");
            return (Criteria) this;
        }

        public Criteria andRedTypeBetween(String value1, String value2) {
            addCriterion("redType between", value1, value2, "redType");
            return (Criteria) this;
        }

        public Criteria andRedTypeNotBetween(String value1, String value2) {
            addCriterion("redType not between", value1, value2, "redType");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidIsNull() {
            addCriterion("questionUuid is null");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidIsNotNull() {
            addCriterion("questionUuid is not null");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidEqualTo(String value) {
            addCriterion("questionUuid =", value, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidNotEqualTo(String value) {
            addCriterion("questionUuid <>", value, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidGreaterThan(String value) {
            addCriterion("questionUuid >", value, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidGreaterThanOrEqualTo(String value) {
            addCriterion("questionUuid >=", value, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidLessThan(String value) {
            addCriterion("questionUuid <", value, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidLessThanOrEqualTo(String value) {
            addCriterion("questionUuid <=", value, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidLike(String value) {
            addCriterion("questionUuid like", value, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidNotLike(String value) {
            addCriterion("questionUuid not like", value, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidIn(List<String> values) {
            addCriterion("questionUuid in", values, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidNotIn(List<String> values) {
            addCriterion("questionUuid not in", values, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidBetween(String value1, String value2) {
            addCriterion("questionUuid between", value1, value2, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andQuestionUuidNotBetween(String value1, String value2) {
            addCriterion("questionUuid not between", value1, value2, "questionUuid");
            return (Criteria) this;
        }

        public Criteria andRedStatusIsNull() {
            addCriterion("redStatus is null");
            return (Criteria) this;
        }

        public Criteria andRedStatusIsNotNull() {
            addCriterion("redStatus is not null");
            return (Criteria) this;
        }

        public Criteria andRedStatusEqualTo(String value) {
            addCriterion("redStatus =", value, "redStatus");
            return (Criteria) this;
        }

        public Criteria andRedStatusNotEqualTo(String value) {
            addCriterion("redStatus <>", value, "redStatus");
            return (Criteria) this;
        }

        public Criteria andRedStatusGreaterThan(String value) {
            addCriterion("redStatus >", value, "redStatus");
            return (Criteria) this;
        }

        public Criteria andRedStatusGreaterThanOrEqualTo(String value) {
            addCriterion("redStatus >=", value, "redStatus");
            return (Criteria) this;
        }

        public Criteria andRedStatusLessThan(String value) {
            addCriterion("redStatus <", value, "redStatus");
            return (Criteria) this;
        }

        public Criteria andRedStatusLessThanOrEqualTo(String value) {
            addCriterion("redStatus <=", value, "redStatus");
            return (Criteria) this;
        }

        public Criteria andRedStatusLike(String value) {
            addCriterion("redStatus like", value, "redStatus");
            return (Criteria) this;
        }

        public Criteria andRedStatusNotLike(String value) {
            addCriterion("redStatus not like", value, "redStatus");
            return (Criteria) this;
        }

        public Criteria andRedStatusIn(List<String> values) {
            addCriterion("redStatus in", values, "redStatus");
            return (Criteria) this;
        }

        public Criteria andRedStatusNotIn(List<String> values) {
            addCriterion("redStatus not in", values, "redStatus");
            return (Criteria) this;
        }

        public Criteria andRedStatusBetween(String value1, String value2) {
            addCriterion("redStatus between", value1, value2, "redStatus");
            return (Criteria) this;
        }

        public Criteria andRedStatusNotBetween(String value1, String value2) {
            addCriterion("redStatus not between", value1, value2, "redStatus");
            return (Criteria) this;
        }

        public Criteria andPayTypeIsNull() {
            addCriterion("payType is null");
            return (Criteria) this;
        }

        public Criteria andPayTypeIsNotNull() {
            addCriterion("payType is not null");
            return (Criteria) this;
        }

        public Criteria andPayTypeEqualTo(String value) {
            addCriterion("payType =", value, "payType");
            return (Criteria) this;
        }

        public Criteria andPayTypeNotEqualTo(String value) {
            addCriterion("payType <>", value, "payType");
            return (Criteria) this;
        }

        public Criteria andPayTypeGreaterThan(String value) {
            addCriterion("payType >", value, "payType");
            return (Criteria) this;
        }

        public Criteria andPayTypeGreaterThanOrEqualTo(String value) {
            addCriterion("payType >=", value, "payType");
            return (Criteria) this;
        }

        public Criteria andPayTypeLessThan(String value) {
            addCriterion("payType <", value, "payType");
            return (Criteria) this;
        }

        public Criteria andPayTypeLessThanOrEqualTo(String value) {
            addCriterion("payType <=", value, "payType");
            return (Criteria) this;
        }

        public Criteria andPayTypeLike(String value) {
            addCriterion("payType like", value, "payType");
            return (Criteria) this;
        }

        public Criteria andPayTypeNotLike(String value) {
            addCriterion("payType not like", value, "payType");
            return (Criteria) this;
        }

        public Criteria andPayTypeIn(List<String> values) {
            addCriterion("payType in", values, "payType");
            return (Criteria) this;
        }

        public Criteria andPayTypeNotIn(List<String> values) {
            addCriterion("payType not in", values, "payType");
            return (Criteria) this;
        }

        public Criteria andPayTypeBetween(String value1, String value2) {
            addCriterion("payType between", value1, value2, "payType");
            return (Criteria) this;
        }

        public Criteria andPayTypeNotBetween(String value1, String value2) {
            addCriterion("payType not between", value1, value2, "payType");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}